#!/bin/bash
#http://www.runoob.com/linux/linux-shell-variable.html

funWithParam(){
    echo "One $1 !"
    echo "One $10 !"
    echo "One ${10} !"
    echo "As a whole $* !"
}
funWithParam 91 2 3 4 5 6 7 8 9 34 73

int=100
while(( $int<=5 ))
do
    echo $int
    let "int++"
done

num1=$[2*3]
num2=$[1+5]
if test $[num1] -eq $[num2]
then
    echo 'Equals!'
else
    echo 'Not equal!'
fi

echo -e tell us your age: "\c"
#read age
#echo age is $age

la=`expr 23 \* 133 + 323`
echo "$la"

val=`expr 2 + 2`
echo "Sum of : $val"

echo "Hello World!"
sato="japanese"
echo $sato
echo ${sato}
echo $0
echo $1 
echo $2 
echo $3 

echo 1000

for item in "$*"; do
	#echo $item
done

echo "how long? ${#1}"

for item in "$@"; do
	#echo "hello "$item  "WORLD"
done

for skill in Ada Coffe Action Java; do
    #echo "I am good at ${skill}Script"
done

myUrl="http://www.w3cschool.cc"
readonly myUrl
myUrl="http://www.runoob.com"

your_name="qinjx"
greeting="hello, "$your_name" !"
greeting_1="hello, ${your_name} !"
echo $greeting $greeting_1
echo ${#your_name}
echo ${your_name:1:3}
echo `expr index "$your_name" is`
string="runoob is a great company"
echo `expr index "$string" r` 